package org.eiahe.hr.salary.domain.vo;

import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
import cn.idev.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import org.eiahe.hr.salary.domain.SalaryImportRecord;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serial;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

/**
 * 薪资导入记录视图对象 hr_salary_import_record
 *
 * @author zhangnn
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = SalaryImportRecord.class)
public class SalaryImportRecordVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 导入记录ID
     */
    @ExcelProperty(value = "导入记录ID")
    private Long recordId;

    /**
     * 租户ID
     */
    @ExcelProperty(value = "租户ID")
    private String tenantId;

    /**
     * 工号
     */
    @ExcelProperty(value = "工号")
    private String employeeNo;

    /**
     * 员工姓名
     */
    @ExcelProperty(value = "员工姓名")
    private String employeeName;

    /**
     * 年月(yyyyMM格式)
     */
    @ExcelProperty(value = "年月")
    private String yearMonth;

    /**
     * 导入文件名
     */
    @ExcelProperty(value = "导入文件名")
    private String fileName;

    /**
     * 导入状态(0待处理 1处理中 2成功 3失败)
     */
    @ExcelProperty(value = "导入状态")
    private String importStatus;

    /**
     * 总记录数
     */
    @ExcelProperty(value = "总记录数")
    private Integer totalRecords;

    /**
     * 成功记录数
     */
    @ExcelProperty(value = "成功记录数")
    private Integer successRecords;

    /**
     * 失败记录数
     */
    @ExcelProperty(value = "失败记录数")
    private Integer failedRecords;

    /**
     * 错误信息
     */
    @ExcelProperty(value = "错误信息")
    private String errorMessage;

    private Long createBy;

    @ExcelProperty(value = "操作人")
    private String createName;
    /**
     * 创建时间
     */
    @ExcelProperty(value = "创建时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    /**
     * 更新时间
     */
    @ExcelProperty(value = "更新时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;
}
